<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<script src="../vue.js" type="text/javascript" charset="utf-8"></script>
	</head>
	<body>
		<div id="app">
			<hello></hello>
		</div>
	</body>
</html>

<script type="text/x-template" id="tpl">
	<div>
		<button>click</button>	
	</div>
</script>

<script type="text/javascript">
	// 全局注册hello组件
	Vue.component('hello', {
//		template: `<h3>{{msg}}</h3>`,
		template: '#tpl',
		data() {
			return {
				msg: 'hello world'
			}
		},
		created() {
			
		},
		methods: {
			
		}
	})
	
	new Vue({
		el: '#app'
	})
	
	
</script>
